package com.bawei.module_mine.mine

import com.bawei.module_mine.api.MineApi
import com.bawei.module_mine.api.MineModel
import kotlinx.coroutines.flow.flow
import javax.inject.Inject

class MineRepository @Inject constructor() {
    @Inject
    @MineModel.SignApi
    lateinit var mineApi: MineApi
    fun passLogin(password: String,username: String) = flow {
        emit(mineApi.passLogin(password, username))
    }
    fun passRegister(password: String,username: String) = flow {
        emit(mineApi.passRegister(password, username))
    }
    fun modifyPassword(newPwd: String,userid: String) = flow {
        emit(mineApi.modifyPassword(newPwd, userid))
    }
}